package com.min.serviceImpl;

import com.xiaoleilu.hutool.aop.Aspect;

import java.lang.reflect.Method;

/**
 * Created by llx on 2017/5/24.
 */
public class MyProxy extends Aspect {

    public MyProxy(Object target) {
        super(target);
    }

    public boolean before(Object target, Method method, Object[] args) {
        System.out.println(System.currentTimeMillis()+"before");
        return true;
    }

    public boolean after(Object target, Method method, Object[] args) {
        System.out.println(System.currentTimeMillis()+"after");
        return true;
    }

    public boolean afterException(Object target, Method method, Object[] args, Throwable e) {
        return false;
    }
}
